package com.wn.excel.runner;

import com.wn.excel.config.ExportTableProperties;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.ApplicationArguments;
import org.springframework.boot.ApplicationRunner;
import org.springframework.stereotype.Component;

/**
 * @FileName: ApplicationStartRunner
 * @Description: TODO
 * @Author: MaWenHao
 * @Created: 2020/3/3 - 14:15
 * @Version: V1.0
 * @Company: 东方微银科技（北京）有限公司
 */
@Slf4j
@Component
public class ApplicationStartRunner implements ApplicationRunner {

    @Autowired
    private ExportTableProperties exportTableProperties;

    @Override
    public void run(ApplicationArguments args) throws Exception {
        // 初始化列名映射规则
        ExportTableProperties.initColumnMapping(exportTableProperties);
    }
}
